ostbuild: Actually do check for Makefile
authorColin Walters <walters@verbum.org>
Wed, 18 Jan 2012 22:08:30 +0000 (17:08 -0500)
committerColin Walters <walters@verbum.org>
Wed, 18 Jan 2012 22:08:30 +0000 (17:08 -0500)
Just kidding, we need the makefile path to check for .NOTPARALLEL

src/ostbuild/pyostbuild/builtin_compile_one.py

index 88b3d11929fbcf6ae080b15b26d7ce8f7310aff9..cd2983dadd2a49f53d90a74a6da7ced93f257401 100755 (executable)
@@ -152,6 +152,14 @@ class OstbuildCompileOne(builtins.Builtin):
         args.extend(self.configargs)
         run_sync(args, cwd=builddir)
 
+        makefile_path = None
+        for name in ['Makefile', 'makefile', 'GNUmakefile']:
+            makefile_path = os.path.join(builddir, name)
+            if os.path.exists(makefile_path):
+                break
+        if makefile_path is None:
+            fatal("No Makefile found")
+
         args = list(self.makeargs)
         user_specified_jobs = False
         for arg in args: